# @Time : 2020/7/24 15:50
# @Author : Fioman 
# @Phone : 13149920693

import cv2 as cv
import numpy as np


img = cv.imread("cutter.bmp",cv.IMREAD_GRAYSCALE)
T,thres = cv.threshold(img,0,255,cv.THRESH_OTSU|cv.THRESH_BINARY)
cv.imwrite("new_cutter.bmp",thres)